package com.junxonline.instant.dao.mapper.config;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.junxonline.instant.dao.entity.model.config.Role;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 系统角色表Mapper
 *
 * @author JunX
 * @date 2021-07-04
 */
@Repository
public interface RoleMapper extends BaseMapper<Role> {

    IPage<Role> queryList(Page<Role> page, @Param("ew") Wrapper<Role> wrapper);

    List<Role> queryRoleList(@Param("ew") Wrapper<Role> wrapper);

    Role selectById(@Param("id") Long id);

    List<Role> selectByUserId(@Param("userId") Long userId);

}
